-- GENERATED SPELL FOR [Atoph the Bloodcursed] --


function spell0_17715(pUnit, Event) --@Rend,n/a--
pUnit:FullCastSpellOnTarget(11977,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17715', 15000, 1)
end

function spell1_17715(pUnit, Event) --@Strike,n/a--
pUnit:FullCastSpellOnTarget(11976,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17715', 509, 1)
end

function Sorts_17715(pUnit, Event)
local choix_sorts_17715 = math.random(0, 1)
if choix_sorts_17715 == 0 then
pUnit:RegisterEvent('spell0_17715', 1, 1)
end
if choix_sorts_17715 == 1 then
pUnit:RegisterEvent('spell1_17715', 1, 1)
end
end

function mob17715_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_17715', math.random(1500, 3000), 1)
end

function mob17715_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17715_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17715_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(17715, 1, 'mob17715_Action')
RegisterUnitEvent(17715, 2, 'mob17715_Leave')
RegisterUnitEvent(17715, 3, 'mob17715_Kill')
RegisterUnitEvent(17715, 4, 'mob17715_Die')
